package com.danielepelagatti.flickrmanager.model
{
	import com.adobe.cairngorm.model.ModelLocator;
	import com.adobe.webapis.flickr.AuthPerm;
	import com.adobe.webapis.flickr.FlickrService;
	import com.adobe.webapis.flickr.Photo;
	import com.adobe.webapis.flickr.User;
	import com.danielepelagatti.flickrmanager.vo.UploadVO;
	import com.theriabook.utils.Logger;
	
	import flash.net.SharedObject;
	import flash.utils.Dictionary;
	
	import mx.collections.ArrayCollection;
	import mx.utils.ObjectProxy;
	/**
	 * 
	 * @author dpelagatti
	 * 
	 */
	public class Flickr implements ModelLocator	
	{
		public static const secret:String = "a83c15983445c4be";
		public static const apiKey:String = "21526a85da0e176830ee124f0a85c8ec"; 
		public static var token:String = "";
		public static var frob:String = "";
		/**
		* 
		*/		
		protected static var inst:Flickr;
		/**
		* 
		*/
		public function get service():FlickrService
		{
			
			var s:FlickrService = new FlickrService("21526a85da0e176830ee124f0a85c8ec");
			s.secret 			= "a83c15983445c4be";
			s.permission 		= AuthPerm.DELETE;
			
			return s;
		}
        /**
         * 
         * @return 
         * 
         */		
        public static function getInstance():Flickr
        {
            if(inst == null)
            {
                inst = new Flickr();
            }
            return inst;
        }		
	}
}